<?php
// This PHP script simply gets text from the Data directory.
// We use a PHP script like this so the players cant goto the directory themselfs.

// Please rename the directory and put its name in the quote marks here
// to increase the security of your app.

$Directory_Name = "Game Data Files_RandomTextABCDEF";

//====================================


parse_str( file_get_contents( "php://input" ), $_REQUEST);

if ($_REQUEST['FileURL'] == "")
  {   
 echo "FileNotSpecifiedError";
 die;

  //$FileURL ="Game Message Text/TestText.txt";

  } else
  {
  	$FileURL =  $_REQUEST['FileURL'];
	
  }

$loc = $Directory_Name."/".$FileURL;

//echo 'getting file from '.$loc;


$file = fopen( $loc, "r" );

$text = fread($file, filesize($loc));

fclose( $file );

echo $text;

//====================================

?>